-
Notifications
You must be signed in to change notification settings - Fork 437
Add vLLM Support for GPT OSS and its mapping generator for tunix. #2803
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
69d6317 to
9b0fe8f
Compare
9b0fe8f to
413bfab
Compare
richjames0
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm
|
|
||
| # TODO: Enable multi-host sharding, if there is a mismatch in shapes. | ||
| # # MULTI-HOST case. | ||
| val = jax.device_put(val, current.sharding) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
was it tested at multi-host ?
what sharding do you think it might not work?
| return current.at[..., 0::2].set(val) | ||
|
|
||
| def fuse_interleaved_up(val, tgt_param): | ||
| """Fuse Up (wi_1) with Multi-Host Sharding Support.""" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why Multi-Host is special? do you mean multi-devie or multi-host?
From Jax's perspective I think only number of devices (and sharding) matters.
| return STANDALONE_VLLM_WEIGHT_MAPPING[self.model_name].to_hf_mapping() | ||
| mapping_fn = STANDALONE_VLLM_WEIGHT_MAPPING[self.model_name].to_hf_mapping | ||
| total_num_layers = self.config["num_hidden_layers"] | ||
| print(f"total_num_layers: {total_num_layers} for model: {self.model_name}") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you remove this print or make debug logging (e.g. logging.debug)?
| # TODO: Enable multi-host sharding, if there is a mismatch in shapes. | ||
| # # MULTI-HOST case. | ||
| val = jax.device_put(val, current.sharding) | ||
| val.block_until_ready() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this needed?
Description
Add vLLM Support for GPT OSS and its mapping generator for tunix.
Before submitting this PR, please make sure (put X in square brackets):
(https://maxtext.readthedocs.io/en/latest/development.html#adding-new-documentation-files).kets):
gemini-reviewlabel.